/*
* Header:		MatchingOreManager.h
* ClassName:	CMatchingOreManager
* Author:		MaYuanping
* Date  :		2010.07.19
*/

#pragma once

#include "BlastPile.h"

#include <vector>

class HDiMineView;
class CBlastPileOptimizer;
class CMatchingOreManager
{
public:
	CMatchingOreManager(HDiMineView* pHView);
	~CMatchingOreManager(void);

private:
	bool RemoveBlastPile(void);
	bool EraseBlastPile(int iIndex);

public:
	bool AddBlastPile(const char* pFileName, double dMaxAbility);
	int GetBlastPileCount(void) { return (int)m_vpBlastPile.size(); }
	void GetBlastPile(std::vector<CBlastPile*>& vpBlastPile) { vpBlastPile = m_vpBlastPile; }
	void InitDisplay(void);
	void UpdateDisplay(void);

	CBlastPileOptimizer* GetOptimizer(void) const { return m_pOptimizer; }

private:
	void DestroyBlastPile(void);

private:
	HDiMineView*				m_pView;
	std::vector<CBlastPile*> m_vpBlastPile;
	CBlastPileOptimizer* m_pOptimizer;
	class CDisplayBlastPile* m_pDisplayBlastPile;
};
